package org.reos.ReParser;

public enum Bool {
	YES("YES"), NO("NO");
	
	private String value;
	private Bool(String value) {
		this.value = value;
	}
	@Override
	public String toString() {
		return this.value; 
	}
	
	public boolean toBoolean() {
		return ((this == YES) ? true : false);
	}
	
	public static boolean isBool(String str) {
		if (str.equals(YES.toString()) || str.equals(NO.toString())) {
			return true;
		}
		return false;
	}

    public static boolean toBoolean(String boolStr) {
        return ((boolStr.equals(YES.toString())) ? true : false);
    }
}
